home *** CD-ROM | disk | FTP | other *** search
/ Winzipper / Winzipper_ISO.iso / nt4.0 server / DRVLIB.NIC / OCE4XMP / OEMSETUP.INF < prev   
INI File  |  1996-07-31  |  37KB  |  1,126 lines

  1. ;***********************************************************************
  2. ;
  3. ; OEMSETNT.INF
  4. ;
  5. ;       Olicom network card and driver SETUP INF file.
  6. ;
  7. ;***********************************************************************
  8.  
  9. ;-----------------------------------------------------------------------
  10. ; OPTION TYPE
  11. ; -----------
  12. ; This identifies the Option type we are dealing with.  The different
  13. ; possible types are:
  14. ;
  15. ; COMPUTER, DISPLAY, MOUSE, KEYBOARD, LAYOUT, SCSI, PRINTER, ...
  16. ;
  17. ;  Types specific to networking:
  18. ;
  19. ; NetAdapter,        a netcard / adapter combination or just a netcard
  20. ; NetDriver,         just a netcard driver
  21. ; NetTransport,      a complete NDIS-compliant TDI transport stack
  22. ; NetService,        an NT networking service
  23. ; NetWork,           a complete network ensemble.
  24. ; NetProvider        a complete network which supports NT MPR protocol
  25. ;-----------------------------------------------------------------------
  26.  
  27. [Identification]
  28.     OptionType = NetAdapter
  29.  
  30. ;-----------------------------------------------------------------------
  31. ; PlatformsSupported
  32. ; ------------------
  33. ; This identifies the platforms supported by the adapter card.
  34. ; Possible types are:
  35. ;
  36. ; ISA and EISA
  37. ;-----------------------------------------------------------------------
  38.  
  39. [PlatformsSupported]
  40.     PCI
  41.  
  42. [LanguagesSupported]
  43.     ENG
  44.  
  45. ;-----------------------------------------------------------------------
  46. ; OPTION LIST
  47. ; -----------
  48. ; This section lists the OEM Option key names.  These keys are locale
  49. ; independent and used to represent the option in a locale independent
  50. ; manner.
  51. ;
  52. ;-----------------------------------------------------------------------
  53.  
  54. [Options]
  55.     OCE4XMP10
  56.     OCE4XMP100
  57.  
  58. [OptionsTextENG]
  59.     OCE4XMP10  = "Olicom Ethernet PCI/II 10 Adapter"
  60.     OCE4XMP100 = "Olicom Ethernet PCI/II 10/100 Adapter"
  61.  
  62. [XmitBufCountChoices]
  63. TB_4 = "4",4
  64. TB_5 = "5",5
  65. TB_6 = "6",6
  66. TB_7 = "7",7
  67. TB_8 = "8",8
  68. TB_9 = "9",9
  69. TB_10 = "10",10
  70. TB_11 = "11",11
  71. TB_12 = "12",12
  72. TB_13 = "13",13
  73. TB_14 = "14",14
  74. TB_15 = "15",15
  75. TB_16 = "16",16
  76.  
  77. [RecBufCountChoices]
  78. RB_4 = "4",4
  79. RB_5 = "5",5
  80. RB_6 = "6",6
  81. RB_7 = "7",7
  82. RB_8 = "8",8
  83. RB_9 = "9",9
  84. RB_10 = "10",10
  85. RB_11 = "11",11
  86. RB_12 = "12",12
  87. RB_13 = "13",13
  88. RB_14 = "14",14
  89. RB_15 = "15",15
  90. RB_16 = "16",16
  91.  
  92. [SpeedChoices]
  93. ;;;SP_1 = "Auto negotiate",0
  94. SP_2 = "10 Mbps",10
  95. ;;;SP_3 = "100 Mbps",100
  96.  
  97. [DuplexChoices]
  98. LM_1 = "Auto negotiate",0
  99. LM_2 = "Half duplex",1
  100. LM_3 = "Full duplex",2
  101.  
  102. [BusNumberChoices]
  103. BusNo_1 = "0",0
  104. BusNo_2 = "1",1
  105. BusNo_3 = "2",2
  106. BusNo_4 = "3",3
  107. BusNo_5 = "4",4
  108. BusNo_6 = "5",5
  109. BusNo_7 = "6",6
  110. BusNo_8 = "7",7
  111.  
  112. ;-----------------------------------------------------------------------
  113. ; Constants for use with dialogs
  114. ;-----------------------------------------------------------------------
  115.  
  116. [FileConstants]
  117. UtilityInf      = "UTILITY.INF"
  118. subroutineinf   = "SUBROUTN.INF"
  119. SoftwareType    = "driver"
  120. Exit_Code       = 0
  121. DialogDllName   = "oce4xmp.dll"
  122. HelpfileName    = "oce4xmp.hlp"
  123. NetEventDLL     = "%SystemRoot%\System32\netevent.dll;%SystemRoot%\System32\Drivers\Oc2xem.sys"
  124. IoLogMsgDLL     = "%SystemRoot%\System32\IoLogMsg.dll"
  125. Manufacturer    = "Olicom"
  126. ProductMajorVersion     = "3"
  127. ProductMinorVersion     = "0"
  128. ProductVersion          = $(ProductMajorVersion)"."$(ProductMinorVersion)
  129. ProductSoftwareName     = "OCE4XMP"
  130. ProductSoftwareTitle    = "Olicom Ethernet PCI/II 10/100 Adapter Driver"
  131. ProductSoftwareImagePath = "\SystemRoot\System32\drivers\oce4xmp.sys"
  132. NetRuleSoftwareType     = "oce4xmpSys ndisDriver oce4xmpDriver"
  133. NetRuleSoftwareUse      = $(SoftwareType)
  134. NetRuleSoftwareBindForm = """Oce4xMPSys"" yes no container"
  135. NetRuleSoftwareClass    = {"oce4xmpDriver basic"}
  136. NetRuleSoftwareBindable = {"oce4xmpDriver oce4xmpAdapter non exclusive 100"}
  137. ProductHardwareName     = "OCE4XMP"
  138. ProductHardwareTitle    = "Olicom Ethernet PCI/II 10/100 Adapter"
  139. ProductHardwareOCE4XMP10Title    = "Olicom Ethernet PCI/II 10 Adapter"
  140. ProductHardwareOCE4XMP100Title    = "Olicom Ethernet PCI/II 10/100 Adapter"
  141. NetRuleHardwareType     = "oce4xmp oce4xmpAdapter"
  142. NetRuleHardwareBindForm = " yes yes container"
  143. NetRuleHardwareClass    = {"oce4xmpAdapter basic"}
  144. ProductKeyName  = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareName)"\CurrentVersion"
  145. ParamKeyName    = $(!NTN_ServiceBase)"\"$(ProductHardwareName)"\Parameters"
  146.  
  147. [GeneralConstants]
  148. from      = ""
  149. to        = ""
  150. ExitCodeOk     = 0
  151. ExitCodeCancel = 1
  152. ExitCodeFatal  = 2
  153. KeyNull         = ""
  154. MAXIMUM_ALLOWED   = 33554432
  155. RegistryErrorIndex = NO_ERROR
  156. KeyProduct      = ""
  157. KeyParameters   = ""
  158. TRUE            = 1
  159. FALSE           = 0
  160. NoTitle         = 0
  161. ExitState       = "Active"
  162. OldVersionExisted = $(FALSE)
  163. DriverPath      = $(!STF_NTPATH)\drivers
  164. [FileConstantsENG]
  165. ProCaption   = "Windows NT Setup"
  166. ProCancel    = "Cancel"
  167. ProCancelMsg = "Windows NT Networking is not correctly installed.  "+
  168.            "Are you sure you want to cancel copying files?"
  169. ProCancelCap = "Network Setup Message"
  170. ProText1     = "Copying:"
  171. ProText2     = "To:"
  172. OCE4XMP10FunctionTitle  = "Olicom Ethernet PCI/II 10 Adapter Setup"
  173. OCE4XMP100FunctionTitle    = "Olicom Ethernet PCI/II 10/100 Adapter Setup"
  174. ProductHardwareOCE4XMP10Description = "Olicom Ethernet PCI/II 10 Adapter"
  175. ProductHardwareOCE4XMP100Description   = "Olicom Ethernet PCI/II 10/100 Adapter"
  176. ProductSoftwareDescription          = "Olicom Ethernet PCI/II 10/100 Adapter Driver"
  177. FunctionTitle   = $($(Option)FunctionTitle)
  178.  
  179. XmitBufCountList = ^(XmitBufCountChoices, 1)
  180. XmitBufCountValues = ^(XmitBufCountChoices, 2)
  181. RecBufCountList = ^(RecBufCountChoices, 1)
  182. RecBufCountValues = ^(RecBufCountChoices, 2)
  183. SpeedList = ^(SpeedChoices, 1)
  184. SpeedValues = ^(SpeedChoices, 2)
  185. DuplexList = ^(DuplexChoices, 1)
  186. DuplexValues = ^(DuplexChoices, 2)
  187. BusNoList = ^(BusNumberChoices, 1)
  188. BusNoValues = ^(BusNumberChoices, 2)
  189.  
  190. XmitBufCountDefault = 1
  191. RecBufCountDefault  = 3
  192. SpeedDefault      = 1
  193. DuplexDefault      = 1
  194. BusNoDefault        = 1
  195.  
  196. [DialogConstantsENG]
  197. Help        = "&Help"
  198. Exit        = "Cancel"
  199. OK          = "OK"
  200. HelpContext = ""
  201. Continue    = "Continue"
  202. Cancel      = "Cancel"
  203. ContextMinimumID        = 6000
  204. ContextContentsID       = 6000
  205.  
  206. [date]
  207.     Now = {} ? $(!LIBHANDLE) GetSystemDate
  208.  
  209. [AskSourceDlgText]
  210.     DlgText        = "Please enter the full path of the Olicom Ethernet Adapter "+
  211.              "driver setup files. Then choose Continue."
  212.  
  213. ;-----------------------------------------------------------------------
  214. ; ADAPTER PARAMETER DIALOG
  215. ; ------------------------
  216. ; This section sets up the adapter parameter dialog. All textstrings
  217. ; presented in this dialog are defined here.
  218. ;
  219. ;-----------------------------------------------------------------------
  220.  
  221. [AdapterParameterDlgENG]
  222. DlgType = "RadioCombination"
  223. DlgTemplate = "OCE4DLG"
  224. Caption = $(FunctionTitle)
  225. DlgText = "Please select values for the following fields:"
  226. Combo1Label = "&Transmit Buffers:"
  227. Combo2Label = "&Receive Buffers:"
  228. Combo3Label = "&Speed:"
  229. Combo4Label = "&Duplex mode:"
  230. Combo5Label = "&Bus Number:"
  231. Edit1Label = "&Network Address:"
  232. Combo1List = $(XmitBufCountList)
  233. Combo1Out  = $(XmitBufCountIndex)
  234. Combo2List = $(RecBufCountList)
  235. Combo2Out  = $(RecBufCountIndex)
  236. Combo3List = $(SpeedList)
  237. Combo3Out  = $(SpeedIndex)
  238. Combo4List = $(DuplexList)
  239. Combo4Out  = $(DuplexIndex)
  240. Combo5List = $(BusNoList)
  241. Combo5Out  = $(BusNoIndex)
  242. ComboListItemsIn  = {Combo1List, Combo2List, Combo3List, Combo4List, Combo5List}
  243. ComboListItemsOut = {Combo1Out, Combo2Out, Combo3Out, Combo4Out, Combo5Out}
  244. EditTextLim = 17
  245. EditTextIn = $(NetworkAddress)
  246. RadioOptionGreyed = {}
  247. CBOptionsGreyed = {}
  248. NotifyFields = {NO, NO, NO, NO, NO}
  249. HelpContext = $(ContextContentsID)
  250.  
  251.  
  252. ;---------------------------------------------------------------------------
  253. ; 1. Identify
  254. ;
  255. ; DESCRIPTION:   To verify that this INF deals with the same type of options
  256. ;                as we are choosing currently.
  257. ;
  258. ; INPUT:         None
  259. ;
  260. ; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL
  261. ;                $($R1): Option Type (COMPUTER ...)
  262. ;                $($R2): Diskette description
  263. ;---------------------------------------------------------------------------
  264.  
  265. [Identify]
  266.     read-syms Identification
  267.     set Status     = STATUS_SUCCESSFUL
  268.     set Identifier = $(OptionType)
  269.     set Media      = #("Source Media Descriptions", 1, 1)
  270.     Return $(Status) $(Identifier) $(Media)
  271.  
  272. ;------------------------------------------------------------------------
  273. ; 2. ReturnOptions:
  274. ;
  275. ; DESCRIPTION:   To return the option list supported by this INF and the
  276. ;                localised text list representing the options.
  277. ;
  278. ;
  279. ; INPUT:         $($0):  Language used. ( ENG | FRN | ... )
  280. ;
  281. ; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL |
  282. ;                                STATUS_NOLANGUAGE
  283. ;                                STATUS_FAILED
  284. ;                                STATUS_NOTSUPPORTED
  285. ;
  286. ;                $($R1): Option List
  287. ;                $($R2): Option Text List
  288. ;------------------------------------------------------------------------
  289.  
  290. [ReturnOptions]
  291.     set Status         = STATUS_FAILED
  292.     set OptionList     = {}
  293.     set OptionTextList = {}
  294.     set LanguageList = ^(LanguagesSupported, 1)
  295.     Ifcontains(i) $($0) in $(LanguageList)
  296.     ifstr(i) $($1) == ""
  297.        goto returnoptions
  298.     endif
  299.     set PlatformList = ^(PlatformsSupported, 1)
  300.     Ifcontains(i) $($1) in $(PlatformList)
  301.        goto returnoptions
  302.     else
  303.        set Status = STATUS_NOTSUPPORTED
  304.        goto finish_ReturnOptions
  305.     endif
  306.     else
  307.     set Status = STATUS_NOLANGUAGE
  308.     goto finish_ReturnOptions
  309.     endif
  310. returnoptions = +
  311.     set OptionList     = ^(Options, 1)
  312.     set OptionTextList = ^(OptionsText$($0), 1)
  313.     set Status         = STATUS_SUCCESSFUL
  314. finish_ReturnOptions = +
  315.     Return $(Status) $(OptionList) $(OptionTextList)
  316.  
  317. ;------------------------------------------------------------------------
  318. ;
  319. ; InstallOption:
  320. ;
  321. ;      This section is shelled to by main installation processing
  322. ;      or by NCPASHEL.INF during reconfig, removal, update, etc.
  323. ;
  324. ;
  325. ; FUNCTION:  To copy files representing Options
  326. ;            To configure the installed option
  327. ;            To update the registry for the installed option
  328. ;
  329. ; INPUT:     $($0):  Language to use
  330. ;            $($1):  OptionID to install
  331. ;            $($2):  SourceDirectory
  332. ;            $($3):  AddCopy  (YES | NO)
  333. ;            $($4):  DoCopy   (YES | NO)
  334. ;            $($5):  DoConfig (YES | NO)
  335. ;
  336. ; OUTPUT:    $($R0): STATUS: STATUS_SUCCESSFUL |
  337. ;                            STATUS_NOLANGUAGE |
  338. ;                            STATUS_USERCANCEL |
  339. ;                            STATUS_FAILED
  340. ;
  341. ;------------------------------------------------------------------------
  342.  
  343. [InstallOption]
  344.     StartWait
  345.     set SrcDir   = ""
  346.     set Option   = $($1)
  347.     set SrcDir   = $($2)
  348.     set AddCopy  = $($3)
  349.     set DoCopy   = $($4)
  350.     set DoConfig = $($5)
  351.     ifstr(i) $(SrcDir) == ""
  352.        Set SrcDir = "A:\"
  353.     Endif
  354.     set LanguageList = ^(LanguagesSupported, 1)
  355.     Ifcontains(i) $($0) NOT-IN $(LanguageList)
  356.     Return STATUS_NOLANGUAGE
  357.     endif
  358.     Debug-Output "STF_CWDDIR is: "$(!STF_CWDDIR)
  359.     Debug-Output "STF_LANGUAGE is: "$(!STF_LANGUAGE)
  360.     set-subst LF = "\n"
  361.     read-syms GeneralConstants
  362.     read-syms FileConstants
  363.     read-syms DialogConstants$(!STF_LANGUAGE)
  364.     ifstr(i) $(!NTN_Origination) == "NCPA"
  365.     set Continue = "OK"
  366.     endif
  367.     read-syms FileConstants$(!STF_LANGUAGE)
  368.     detect date
  369.     set-title  $(FunctionTitle)
  370.     set to   = Begin
  371.     set from = Begin
  372.     set CommonStatus = STATUS_SUCCESSFUL
  373.     SetHelpFile $(HelpfileName) 6000 6000
  374.     EndWait
  375. Begin = +
  376.     Ifstr(i) $(!NTN_InstallMode) == deinstall
  377.     set StartLabel = removeadapter
  378.     else-Ifstr(i) $(!NTN_InstallMode) == Update
  379.     set StartLabel = UpgradeSoftware
  380.     else-Ifstr(i) $(!NTN_InstallMode) == bind
  381.     set StartLabel = bindingadapter
  382.     else-Ifstr(i) $(!NTN_InstallMode) == configure
  383.     set StartLabel = configureadapter
  384.     Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  385.         Debug-Output "Cannot configure the driver software."
  386.             Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE
  387.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  388.         Debug-Output "ShellCode error: cannot get an error string."
  389.         goto ShellCodeError
  390.         endif
  391.         set Error = $($R0)
  392.         set from = end
  393.         set to = end
  394.         goto nonfatalinfo
  395.     endif
  396.     else
  397.     set StartLabel = installadapter
  398.     set OEM_ABANDON_OPTIONS = {}
  399.     set OEM_ABANDON_SOFTWARE = FALSE
  400.     set OEM_ABANDON_ON = TRUE
  401.     endif
  402.     set XmitBufCountIndex = *($(XmitBufCountList), $(XmitBufCountDefault))
  403.     set RecBufCountIndex = *($(RecBufCountList), $(RecBufCountDefault))
  404.     ifstr(i) $(Option) == "OCE4XMP100"
  405.        set SpeedList = {"Auto negotiate","10 Mbps","100 Mbps"}
  406.        set SpeedValues = {0,10,100}
  407.     endif
  408.     set SpeedIndex = *($(SpeedList), $(SpeedDefault))
  409.     set DuplexIndex = *($(DuplexList), $(DuplexDefault))
  410.     set BusNoIndex = *($(BusNoList), $(BusNoDefault))
  411.     set NetworkAddress = *($(EditTextOut), 1)
  412.     Shell "" DebugConfiguration "After parameter querying"
  413.     Shell $(UtilityInf), GetBusTypeNum
  414.     set BusTypeNum = $($R1)
  415.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  416.     Debug-Output "ShellCode error."
  417.     goto ShellCodeError
  418.     endif
  419.     Set from = $(fatal)
  420.     Set to = $(fatal)
  421.     Goto $(StartLabel)
  422.  
  423. ;-----------------------------------------------
  424. ; Installation Section
  425. ;-----------------------------------------------
  426. ;
  427. ;   Get the current values of all the parameters
  428. ;
  429. installadapter = +
  430.     OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  431.     Ifstr $(KeyProduct) != $(KeyNull)
  432.     CloseRegKey $(KeyProduct)
  433.     ifstr(i) !(NTN_RegBase) == $(ProductKeyName)
  434.        Shell $(UtilityInf), VerExistedDlg, $(ProductSoftwareTitle),+
  435.            $(ProductVersion)
  436.        ifint $($ShellCode) != $(!SHELL_CODE_OK)
  437.            Debug-Output "ShellCode error: cannot get an error string."
  438.            goto ShellCodeError
  439.        endif
  440.        goto end
  441.     else
  442.        Shell $(UtilityInf), CardExistedDlg
  443.        ifint $($ShellCode) != $(!SHELL_CODE_OK)
  444.            Debug-Output "ShellCode error: cannot get an error string."
  445.            goto ShellCodeError
  446.        endif
  447.        ifstr(i) $($R1) != "OK"
  448.            goto end
  449.        endif
  450.        set OldVersionExisted = $(TRUE)
  451.     endif
  452.     endif
  453.     Shell $(UtilityInf), DoAskSource, $(!STF_CWDDIR), $(SrcDir) NO
  454.     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  455.     Goto ShellCodeError
  456.     Else-Ifstr(i) $($R0) == STATUS_FAILED
  457.     Shell $(UtilityInf) RegistryErrorString "ASK_SOURCE_FAIL"
  458.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  459.         goto ShellCodeError
  460.     endif
  461.     set Error = $($R0)
  462.     Goto fatal
  463.     Else-Ifstr(i) $($R0) == STATUS_USERCANCEL
  464.     Goto successful
  465.     Endif
  466.     Set SrcDir = $($R1)
  467.     install "Install-Dll"
  468.     Goto adapteroptions
  469.  
  470. ;-----------------------------------------------
  471. ; Configuration Section
  472. ;-----------------------------------------------
  473. ;
  474. ;   Get the current values of all the parameters
  475. ;
  476. configureadapter = +
  477.     Ifstr(i) $(KeyProduct) == $(KeyNull)
  478.     OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) KeyProduct
  479.     Ifstr $(KeyProduct) == $(KeyNull)
  480.         set RegistryErrorIndex = CANNOT_FIND_COMPONENT_SERVICE
  481.         Debug-Output "Cannot find component product key"
  482.         goto fatalregistry
  483.     Endif
  484.     Endif
  485.     Debug-Output "INF: Shelling to FindService"
  486.     Shell $(UtilityInf) FindService, $(KeyProduct)
  487.     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  488.     Debug-Output "INF: FindService shell failure"
  489.     Goto ShellCodeError
  490.     Endif
  491.     Ifstr(i) $($R0) != NO_ERROR
  492.     Debug-Output "INF: FindService Shell error: "$($R0)
  493.     Goto fatalregistry
  494.     endif
  495.     Set KeyParameters = $($R2)
  496.     CloseRegKey $($R1)
  497.     Ifstr $(KeyParameters) == $(KeyNull)
  498.     set RegistryErrorIndex = CANNOT_FIND_COMPONENT_SERVICE
  499.     Debug-Output "Cannot find component service"
  500.     goto fatalregistry
  501.     endif
  502.     set OldVersionExisted = $(TRUE)
  503.     set ValueName = ""
  504.     set ValueData = ""
  505.     set ValueStr  = ""
  506.     set ValueList = {}
  507.     EnumRegValue $(KeyParameters) ValueList
  508.     ForListDo $(ValueList)
  509.     set ValueItem = $($)
  510.     set ValueName = *($(ValueItem),1)
  511.     set ValueData = *($(ValueItem),4)
  512.     ifstr(i) $(ValueName) == "XmitBufCount"
  513.         set XmitBufCountValue = $(ValueData)
  514.     else-ifstr(i) $(ValueName) == "RecBufCount"
  515.         set RecBufCountValue = $(ValueData)
  516.     else-ifstr(i) $(ValueName) == "Speed"
  517.         set SpeedValue = $(ValueData)
  518.     else-ifstr(i) $(ValueName) == "Duplex"
  519.         set DuplexString = $(ValueData)
  520.     else-ifstr(i) $(ValueName) == "BusNumber"
  521.         set BusNoValue = $(ValueData)
  522.     else-ifstr(i) $(ValueName) == "NetworkAddress"
  523.         set NetworkAddress = $(ValueData)
  524.     endif
  525.     EndForListDo
  526.     ifstr(i) $(DuplexString) == "HALF"
  527.     set DuplexValue = 1
  528.     else-ifstr(i) $(DuplexString) == "FULL"
  529.     set DuplexValue = 2
  530.     else
  531.     set DuplexValue = 0
  532.     endif
  533.     ;
  534.     ; Combo-lists and radio-buttons use a special list of parameter-names
  535.     ; when dialogs are executed. The following section converts the actual
  536.     ; values into the corresponding names (indexes). If a value is undefined,
  537.     ; the first entry in the index-list is used.
  538.     ;
  539.     set XmitBufCountIndex = *($(XmitBufCountList), ~($(XmitBufCountValues),$(XmitBufCountValue)))
  540.     ifstr(i) $(XmitBufCountIndex) == ""
  541.     set XmitBufCountIndex = *($(XmitBufCountList), 1)
  542.     endif
  543.     set RecBufCountIndex = *($(RecBufCountList), ~($(RecBufCountValues),$(RecBufCountValue)))
  544.     ifstr(i) $(RecBufCountIndex) == ""
  545.     set RecBufCountIndex = *($(RecBufCountList), 1)
  546.     endif
  547.     set SpeedIndex = *($(SpeedList), ~($(SpeedValues),$(SpeedValue)))
  548.     ifstr(i) $(SpeedIndex) == ""
  549.     set SpeedIndex = *($(SpeedList), 1)
  550.     endif
  551.     set DuplexIndex = *($(DuplexList), ~($(DuplexValues),$(DuplexValue)))
  552.     ifstr(i) $(DuplexIndex) == ""
  553.     set DuplexIndex = *($(DuplexList), 1)
  554.     endif
  555.     set BusNoIndex = *($(BusNoList), ~($(BusNoValues),$(BusNoValue)))
  556.     ifstr(i) $(BusNoIndex) == ""
  557.     set BusNoIndex = *($(BusNoList), 1)
  558.     endif
  559.     ;
  560. adapteroptions = +
  561.     set from = adapteroptions
  562.     ifstr(i) $(!STF_GUI_UNATTENDED) == "YES"
  563.     ;
  564.     ; Default parameters for unattended installation
  565.     ;
  566.     goto unattended
  567.     endif
  568.     set OldNetAddress = $(NetworkAddress)
  569.     ;
  570.     ; Load DLL containing dialogs and verification routines
  571.     ;
  572.     LoadLibrary "Olicom Ethernet Driver Disk" $(DialogDllName) DialogHandle
  573.     ;
  574.     ; Read main dialog setup and show dialog
  575.     ;
  576.     read-syms AdapterParameterDlg$(!STF_LANGUAGE)
  577.  
  578.     ui start "InputDlg"  $(DialogHandle)
  579.  
  580.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  581.     ;
  582.     ; parameters have already been stored at this stage
  583.     ;
  584.     ;
  585.     ; Save new settings because this dialog might be called again.
  586.     ; If CANCEL was pressed these values will not be used
  587.     ;
  588.     set XmitBufCountIndex = $(Combo1Out)
  589.     set RecBufCountIndex = $(Combo2Out)
  590.     set SpeedIndex = $(Combo3Out)
  591.     set DuplexIndex = $(Combo4Out)
  592.     set BusNoIndex = $(Combo5Out)
  593.     set NetworkAddress = *($(EditTextOut),1)
  594.     ui pop 1
  595.     goto nextstep
  596.     else-ifstr(i) $(DLGEVENT) == "EXIT"
  597.     set CommonStatus = STATUS_USERCANCEL
  598.     Debug-Output "Action: exit. Bye."
  599.     ui pop 1
  600.     FreeLibrary $(DialogHandle)
  601.     goto end
  602.     else
  603.     ui pop 1
  604.     Debug-Output "Action: unknown: "$(DLGEVENT)
  605.     FreeLibrary $(DialogHandle)
  606.     goto end
  607.     endif
  608.  
  609. nextstep =+
  610.     ifstr $(NetworkAddress) != ""
  611.     ;
  612.     ; If network address has been entered then verify that it is a
  613.     ; valid address (not a multicast or broadcast address)
  614.     ;
  615.     set FLibraryErrCtl = 1
  616.     LibraryProcedure DlgResult $(DialogHandle) VerifyEthAddress $(NetworkAddress)
  617.     set FLibraryErrCtl = 0
  618.     ifstr $(DlgResult) != "STATUS_SUCCESS"
  619.         FreeLibrary $(DialogHandle)
  620.         set Error = $(DlgResult)
  621.         goto nonfatal
  622.     endif
  623.     endif
  624.     FreeLibrary $(DialogHandle)
  625. unattended =+
  626.     ifint $(OldVersionExisted) == $(TRUE)
  627.     ifstr(i) $(!NTN_InstallMode) == configure
  628.         goto writeparameters
  629.     endif
  630.     endif
  631.     StartWait
  632.     Ifint $(OldVersionExisted) != $(FALSE)
  633.     Goto installhardware
  634.     Endif
  635.     ifstr(i) $(!NTN_InstallMode) == "install"
  636.        Ifstr(i) $(DoCopy) == "YES"
  637.       Ifstr(i) $(SrcDir) == ""
  638.          read-syms AskSourceDlgText
  639.          Shell $(subroutineinf) DoAskSourceEx $(SrcDir) $(DlgText)
  640.          Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  641.         Goto ShellCodeError
  642.          Else-Ifstr(i) $($R0) == STATUS_FAILED
  643.          Shell $(UtilityInf) RegistryErrorString "ASK_SOURCE_FAIL"
  644.          ifint $($ShellCode) != $(!SHELL_CODE_OK)
  645.              goto ShellCodeError
  646.          endif
  647.          set Error = $($R0)
  648.          Goto fatal
  649.          Else-Ifstr(i) $($R0) == STATUS_USERCANCEL
  650.          Goto successful
  651.          Endif
  652.          Set SrcDir = $($R1)
  653.       Endif
  654.        Endif
  655.        install "Install-Option"
  656.        ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  657.       Shell $(UtilityInf) RegistryErrorString "UNABLE_COPY_FILE"
  658.       ifint $($ShellCode) != $(!SHELL_CODE_OK)
  659.           goto ShellCodeError
  660.       endif
  661.       set Error = $($R0)
  662.       goto fatal
  663.        endif
  664.     endif
  665.     Shell $(UtilityInf), AddSoftwareComponent, $(Manufacturer), +
  666.     $(ProductSoftwareName), +
  667.     $(ProductSoftwareName), +
  668.     $(ProductSoftwareTitle), $(STF_CONTEXTINFNAME), +
  669.         $(ProductSoftwareImagePath), "kernel", "NDIS", {}, "",+
  670.     $(NetEventDLL), ""
  671.     Set OEM_ABANDON_SOFTWARE = TRUE
  672.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  673.     Debug-Output "ShellCode error"
  674.     goto ShellCodeError
  675.     endif
  676.     set RegistryErrorIndex = $($R0)
  677.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  678.     EndWait
  679.     Debug-Output "OEMNADUB.INF: Registry error: add software components"
  680.     CloseRegKey $($R1)
  681.     CloseRegKey $($R2)
  682.     CloseRegKey $($R3)
  683.     CloseRegKey $($R4)
  684.     CloseRegKey $($R5)
  685.     goto fatalregistry
  686.     endif
  687.     set SoftProductKey  = $($R1)
  688.     Set SoftNetRuleKey = $($R2)
  689.     Set SoftServiceKey  = $($R3)
  690.     Set SoftParameterKey        = $($R4)
  691.     Set SoftLinkageKey  = $($R5)
  692.     set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+
  693.                {MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersion)},+
  694.                {MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersion)},+
  695.                {Title,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareTitle)},+
  696.                {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareDescription)},+
  697.                {ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareName)},+
  698.                {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  699.     Shell  $(UtilityInf), AddValueList, $(SoftProductKey), $(NewValueList)
  700.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  701.     Debug-Output "ShellCode error."
  702.     goto ShellCodeError
  703.     endif
  704.     set RegistryErrorIndex = $($R0)
  705.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  706.     EndWait
  707.     Debug-Output "Registry error: add value list."
  708.     CloseRegKey $(SoftProductKey)
  709.     CloseRegKey $(SoftNetRuleKey)
  710.     CloseRegKey $(SoftServiceKey)
  711.     CloseRegKey $(SoftParameterKey)
  712.     CloseRegKey $(SoftLinkageKey)
  713.     goto fatalregistry
  714.     endif
  715.     set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareType)},+
  716.             {use,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareUse)}, +
  717.             {bindform,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareBindForm)}, +
  718.             {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareClass)}, +
  719.             {bindable,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareBindable)}, +
  720.             {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  721.     Shell  $(UtilityInf), AddValueList, $(SoftNetRuleKey), $(NewValueList)
  722.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  723.     Debug-Output "ShellCode error."
  724.     goto ShellCodeError
  725.     endif
  726.     set RegistryErrorIndex = $($R0)
  727.     CloseRegKey $(SoftProductKey)
  728.     CloseRegKey $(SoftNetRuleKey)
  729.     CloseRegKey $(SoftServiceKey)
  730.     CloseRegKey $(SoftParameterKey)
  731.     CloseRegKey $(SoftLinkageKey)
  732.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  733.     EndWait
  734.     Debug-Output "Registry error: add value list."
  735.     goto fatalregistry
  736.     endif
  737. ;
  738. ;   Insert hardware component in registry
  739. ;
  740. installhardware =+
  741.     Shell $(UtilityInf), AddHardwareComponent, $(ProductHardwareName),$(STF_CONTEXTINFNAME),$(ProductKeyName)
  742.     ifint $($R4) != -1
  743.     Set OEM_ABANDON_OPTIONS = >($(OEM_ABANDON_OPTIONS), $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$($R4))
  744.     endif
  745.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  746.     Debug-Output "Cannot add hardware component"
  747.     goto ShellCodeError
  748.     endif
  749.     set RegistryErrorIndex = $($R0)
  750.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  751.     EndWait
  752.     Debug-Output "Registry error: add hardware component"
  753.     CloseRegKey $($R1)
  754.     CloseRegKey $($R2)
  755.     CloseRegKey $($R3)
  756.     goto fatalregistry
  757.     endif
  758.     set KeyProduct = $($R1)
  759.     set KeyAdapterRules = $($R2)
  760.     set KeyParameters = $($R3)
  761.     set AdapterNumber = $($R4)
  762.     set NewValueList = {{Manufacturer,$(NoTitle),$(!REG_VT_SZ),$(Manufacturer)},+
  763.                {Title,$(NoTitle),$(!REG_VT_SZ),"["$($R4)"] "$(ProductHardware$(Option)Title)},+
  764.                {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductHardware$(Option)Description)},+
  765.                {ProductName,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareName)},+
  766.                {ServiceName,$(NoTitle),$(!REG_VT_SZ),$($R5)},+
  767.                {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  768.     Shell  $(UtilityInf), AddValueList, $(KeyProduct), $(NewValueList)
  769.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  770.     Debug-Output "ShellCode error"
  771.     goto ShellCodeError
  772.     endif
  773.     CloseRegKey $(KeyProduct)
  774.     Set KeyProduct = ""
  775.     set TempProdName = """"$(ProductHardwareName)$(AdapterNumber)""""
  776.     set TempBindForm = $(TempProdName)$(NetRuleHardwareBindForm)
  777.     set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleHardwareType)},+
  778.             {bindform,$(NoTitle),$(!REG_VT_SZ),$(TempBindForm)}, +
  779.             {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleHardwareClass)}, +
  780.             {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  781.     Shell  $(UtilityInf), AddValueList, $(KeyAdapterRules), $(NewValueList)
  782.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  783.     Debug-Output "ShellCode error."
  784.     goto ShellCodeError
  785.     endif
  786.     CloseRegKey $(KeyAdapterRules)
  787.     set RegistryErrorIndex = $($R0)
  788.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  789.     EndWait
  790.     Debug-Output "Registry error: add value list."
  791.     CloseRegKey $(KeyParameters)
  792.     goto fatalregistry
  793.     endif
  794. ;
  795. ; Write Adapter Parameters to registry
  796. ;
  797. writeparameters = +
  798.     Shell $(UtilityInf), GetBusTypeNum
  799.     set BusTypeNum = $($R1)
  800.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  801.     Debug-Output "ShellCode error."
  802.     goto ShellCodeError
  803.     endif
  804.     Ifstr(i) $(KeyParameters) == $(KeyNull)
  805.     Debug-Output "*** KeyParameters is NULL at writeparameters"
  806.     Endif
  807.     ;
  808.     ; Convert selections from combo-lists and radio-buttons into actual
  809.     ; parameter values
  810.     ;
  811.     set XmitBufCountValue = *($(XmitBufCountValues), ~($(XmitBufCountList),$(XmitBufCountIndex)))
  812.     set RecBufCountValue = *($(RecBufCountValues), ~($(RecBufCountList),$(RecBufCountIndex)))
  813.     set SpeedValue = *($(SpeedValues), ~($(SpeedList),$(SpeedIndex)))
  814.     set DuplexValue = *($(DuplexValues), ~($(DuplexList),$(DuplexIndex)))
  815.     ifint $(DuplexValue) == 0
  816.        set DuplexString = "AUTO"
  817.     else-ifint $(DuplexValue) == 1
  818.        set DuplexString = "HALF"
  819.     else-ifint $(DuplexValue) == 2
  820.        set DuplexString = "FULL"
  821.     Endif
  822.     set BusNoValue = *($(BusNoValues), ~($(BusNoList),$(BusNoIndex)))
  823.     ;
  824.     ; Set up parameter list for AddValueList routine
  825.     ;
  826.     set NewValueList = {{XmitBufCount,$(NoTitle),$(!REG_VT_DWORD),$(XmitBufCountValue)},+
  827.             {MediaType,$(NoTitle),$(!REG_VT_DWORD),1},+
  828.             {BusType,$(NoTitle),$(!REG_VT_DWORD),$(BusTypeNum)},+
  829.             {BusNumber,$(NoTitle),$(!REG_VT_DWORD),$(BusNoValue)},+
  830.             {Speed,$(NoTitle),$(!REG_VT_DWORD),$(SpeedValue)},+
  831.             {Duplex,$(NoTitle),$(!REG_VT_SZ),$(DuplexString)},+
  832.             {RecBufCount,$(NoTitle),$(!REG_VT_DWORD),$(RecBufCountValue)}}
  833.     ifstr $(NetworkAddress) != ""
  834.        set NewValueList = >($(NewValueList),{NetworkAddress,$(NoTitle),$(!REG_VT_SZ),$(NetworkAddress)})
  835.     endif
  836.     ;
  837.     ; Now update registry
  838.     ;
  839.     Shell  $(UtilityInf), AddValueList, $(KeyParameters), $(NewValueList)
  840.     ifstr(i) $(!STF_GUI_UNATTENDED) == "YES"
  841.     Shell $(UtilityInf),AddDefaultNetCardParameters,$(KeyParameters)
  842.     endif
  843.     ;
  844.     ; If the network address has been deleted then also delete it from
  845.     ; the registry.
  846.     ;
  847.     ifstr $(OldNetAddress) != ""
  848.        ifstr $(NetworkAddress) == ""
  849.       DeleteRegValue $(KeyParameters) NetworkAddress
  850.        endif
  851.     endif
  852.     CloseRegKey $(KeyParameters)
  853.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  854.     Debug-Output "ShellCode error."
  855.     goto ShellCodeError
  856.     endif
  857.     set RegistryErrorIndex = $($R0)
  858.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  859.     Debug-Output "Registry error: Add value list"
  860.     goto fatalregistry
  861.     endif
  862.     EndWait
  863.     goto successful
  864.  
  865. bindingadapter =+
  866.     set Error = "Binding: Sorry, not yet implemented."
  867.     goto fatal
  868.  
  869. ;-----------------------------------------------
  870. ; Remove Adapter Section
  871. ;-----------------------------------------------
  872. ;
  873. ;   Remove all adapter information from the registry
  874. ;
  875. removeadapter = +
  876.     Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  877.     Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
  878.         $(ProductSoftwareName)
  879.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  880.         Debug-Output "ShellCode error"
  881.         goto ShellCodeError
  882.     endif
  883.     set RegistryErrorIndex = $($R0)
  884.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  885.         goto fatalregistry
  886.     endif
  887.     else
  888.     Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
  889.         $(ProductSoftwareName), $(!NTN_RegBase)
  890.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  891.         Debug-Output "ShellCode error"
  892.         goto ShellCodeError
  893.     endif
  894.     set RegistryErrorIndex = $($R0)
  895.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  896.         goto fatalregistry
  897.     endif
  898.     endif
  899.     goto end
  900.  
  901. UpgradeSoftware = +
  902.     ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  903.     OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  904.     Ifstr $(KeyProduct) != $(KeyNull)
  905.         GetRegValue $(KeyProduct),"MajorVersion", VersionInfo
  906.         set Version = *($(VersionInfo), 4)
  907.         Shell $(UtilityInf), GetInfFileNameFromRegistry, $(KeyProduct)
  908.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  909.         Debug-Output "ShellCode error"
  910.         goto ShellCodeError
  911.         endif
  912.         set !UG_Filename = $($R0)
  913.         ifstr(i) $(!UG_Filename) != ""
  914.         install "Install-Update"
  915.         ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  916.             goto fatal
  917.         endif
  918.         endif
  919.         SetRegValue $(KeyProduct) {MajorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMajorVersion)}
  920.         SetRegValue $(KeyProduct) {MinorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMinorVersion)}
  921.         ifint $(Version) != $(ProductVersion)
  922.         endif
  923.         CloseRegKey $(KeyProduct)
  924.     else
  925.         goto fatalregistry
  926.     endif
  927.     else
  928.     OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) +
  929.           $(MAXIMUM_ALLOWED) NetworkCardKey
  930.     Ifstr(i) $(NetworkCardKey) != $(KeyNull)
  931.         GetRegValue $(NetworkCardKey),"ServiceName", ServiceNameInfo
  932.         set ServiceName = *($(ServiceNameInfo), 4)
  933.         OpenRegKey $(NetworkCardKey) "" "NetRules" +
  934.         $(MAXIMUM_ALLOWED) NetRuleKey
  935.         Ifstr(i) $(NetRuleKey) != $(KeyNull)
  936.         else
  937.         CloseRegKey $(NetworkCardKey)
  938.         goto fatalregistry
  939.         endif
  940.         CloseRegKey $(NetRules)
  941.         CloseRegKey $(NetworkCardKey)
  942.     else
  943.         goto fatalregistry
  944.     endif
  945.     OpenRegKey $(!REG_H_LOCAL) "" +
  946.           $(!NTN_ServiceBase)"\"$(ServiceName) +
  947.           $(MAXIMUM_ALLOWED) ServiceKey
  948.     Ifstr(i) $(ServiceKey) != $(KeyNull)
  949.         CloseRegKey $(ServiceKey)
  950.     else
  951.         goto fatalregistry
  952.     endif
  953.     endif
  954.     goto end
  955. successful = +
  956.     goto end
  957. abandon = +
  958.     ForListDo $(OEM_ABANDON_OPTIONS)
  959.     Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
  960.         $(ProductSoftwareName), $($)
  961.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  962.         Debug-Output "ShellCode error"
  963.         goto ShellCodeError
  964.     endif
  965.     set RegistryErrorIndex = $($R0)
  966.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  967.         goto fatalregistry
  968.     endif
  969.     EndForListDo
  970.     Ifstr(i) $(OEM_ABANDON_SOFTWARE) == TRUE
  971.     Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
  972.         $(ProductSoftwareName), FALSE
  973.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  974.         Debug-Output "ShellCode error"
  975.         goto ShellCodeError
  976.     endif
  977.     set RegistryErrorIndex = $($R0)
  978.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  979.         goto fatalregistry
  980.     endif
  981.     endif
  982.     goto end
  983. warning = +
  984.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "WARNING", $(Error)
  985.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  986.     goto ShellCodeError
  987.     endif
  988.     ifstr(i) $($R1) == "OK"
  989.     goto $(to)
  990.     else-ifstr(i) $($R1) == "CANCEL"
  991.     goto $(from)
  992.     else
  993.     goto "end"
  994.     endif
  995. nonfatalinfo = +
  996.     Set Severity = STATUS
  997.     Set CommonStatus = STATUS_USERCANCEL
  998.     goto nonfatalmsg
  999. nonfatal = +
  1000.     Set Severity = NONFATAL
  1001.     goto nonfatalmsg
  1002. nonfatalmsg = +
  1003.     ifstr(i) $(Error) == ""
  1004.     Set Severity = NONFATAL
  1005.     Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  1006.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1007.         goto ShellCodeError
  1008.     endif
  1009.     set Error = $($R0)
  1010.     endif
  1011.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), $(Severity), $(Error)
  1012.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1013.     goto ShellCodeError
  1014.     endif
  1015.     ifstr(i) $($R1) == "OK"
  1016.     goto $(from)
  1017.     else
  1018.     goto "end"
  1019.     endif
  1020. fatalregistry = +
  1021.     Shell "subroutn.inf" SetupMessage $(!STF_LANGUAGE) WARNING "Fatal Error"
  1022.     Shell $(UtilityInf) RegistryErrorString $(RegistryErrorIndex)
  1023.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1024.     goto ShellCodeError
  1025.     endif
  1026.     set Error = $($R0)
  1027.     goto fatal
  1028. fatal = +
  1029.     ifstr(i) $(Error) == ""
  1030.     Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  1031.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1032.         goto ShellCodeError
  1033.     endif
  1034.     set Error = $($R0)
  1035.     endif
  1036.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "FATAL", $(Error)
  1037.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  1038.     goto ShellCodeError
  1039.     endif
  1040.     goto setfailed
  1041. ShellCodeError = +
  1042.     set DlgType      = "MessageBox"
  1043.     set STF_MB_TITLE = "Error: "$(FunctionTitle)
  1044.     set STF_MB_TEXT  = "Shell Code Error"
  1045.     set STF_MB_TYPE  = 1
  1046.     set STF_MB_ICON  = 3
  1047.     set STF_MB_DEF   = 1
  1048.     ui start "Error Message"
  1049.     goto setfailed
  1050. setfailed = +
  1051.     set CommonStatus = STATUS_FAILED
  1052.     ifstr(i) $(OEM_ABANDON_ON) == TRUE
  1053.     set OEM_ABANDON_ON = FALSE
  1054.     goto abandon
  1055.     endif
  1056.     goto end
  1057. end = +
  1058.     goto term
  1059. term = +
  1060.     Return $(CommonStatus)
  1061.  
  1062. [Install-Option]
  1063.     set STF_VITAL = ""
  1064.     ifstr(i) $(AddCopy) == "YES"
  1065.     AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
  1066.     endif
  1067.     Debug-Output "OEMSETNT.INF: [Install-Option] DoCopy = "$(DoCopy)
  1068.     ifstr(i) $(DoCopy) == "YES"
  1069.        set !STF_NCPA_FLUSH_COPYLIST = TRUE
  1070.        CopyFilesInCopyList
  1071.     endif
  1072.     Exit
  1073.  
  1074. [Install-Update]
  1075.    set STF_VITAL        = ""
  1076.    set STF_OVERWRITE    = "VERIFYSOURCEOLDER"
  1077.    AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
  1078.    AddSectionFilesToCopyList Files-Inf $(SrcDir) $(!STF_WINDOWSSYSPATH)
  1079.    AddSectionFilesToCopyList Files-Dll $(SrcDir) $(!STF_WINDOWSSYSPATH)
  1080.    set !STF_NCPA_FLUSH_COPYLIST = TRUE
  1081.    CopyFilesInCopyList
  1082.    exit
  1083.  
  1084. [Install-Dll]
  1085.    set STF_VITAL        = ""
  1086.  
  1087. ;   ifstr(i) $(AddCopy) == "YES"
  1088.       AddSectionFilesToCopyList Files-Dll $(SrcDir) $(!STF_WINDOWSSYSPATH)
  1089. ;   endif
  1090.  
  1091. ;   ifstr(i) $(DoCopy) == "YES"
  1092.       set !STF_NCPA_FLUSH_COPYLIST = TRUE
  1093.       CopyFilesInCopyList
  1094. ;   endif
  1095.    exit
  1096.  
  1097. [Source Media Descriptions]
  1098. ;   1  = "Olicom Ethernet PCI/II 10/100 Driver Disk"
  1099.     1  = "Windows NT DRVLIB"
  1100.  
  1101. [Signature]
  1102.     FileType = MICROSOFT_DRVLIB_FILE
  1103. [GetSignature]
  1104.     read-syms Signature
  1105.     return $(FileType)
  1106.  
  1107. [ProductType]
  1108. STF_PRODUCT  = Winnt
  1109. STF_PLATFORM = I386
  1110.  
  1111. [Files-Inf]
  1112. 1, oemsetnt.inf, SIZE=999,       RENAME=$(!UG_Filename)
  1113.  
  1114. [Files-OCE4XMP100]
  1115. 1, OCE4XMP.SYS,  SIZE=999
  1116.  
  1117. [Files-OCE4XMP10]
  1118. 1, OCE4XMP.SYS,  SIZE=999
  1119.  
  1120. [Files-Dll]
  1121. 1, oce4xmp.dll,  SIZE=999
  1122. 1, oce4xmp.hlp,  SIZE=999
  1123. 1, ocmpstat.exe, SIZE=999
  1124.  
  1125. [Files-dummy]
  1126.